<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<html>
<head>
<title>修改资源信息</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css"
	href="${pageContext.request.contextPath}/static/bootstrap-3.3.5-dist/css/bootstrap.css" />

</head>
<body>
	<div class="row-fluid" style="margin-top: 10px;">
		<div class="col-md-6">
			<h3>修改资源信息</h3>
			<form role="form" class="form-horizontal"
				action="${pageContext.request.contextPath}/reporters/updatemReportersAction "
				method="post" id="checkForm">
				<div class="form-group">
					<label class="col-md-3 control-label" for="name">名称</label>
					<div class="col-md-9">
						<input class="form-control" name="mbean.name"
							value="${list.name }" type="text" />
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label">类别</label>
					<div class="col-md-9">
						<select name="mbean.type" class="form-control"
							value="${list.type }">
							<c:choose>
								<c:when test="${list.type=='食物' }">
									<option value="食物">食物</option>
									<option value="生活用品">生活用品</option>
									<option value="材料设备">材料设备</option>
									<option value="机械设备">机械设备</option>
									<option value="其他">其他</option>
								</c:when>
								<c:when test="${list.type=='生活用品' }">
									<option value="生活用品">生活用品</option>
									<option value="食物">食物</option>
									<option value="材料设备">材料设备</option>
									<option value="机械设备">机械设备</option>
									<option value="其他">其他</option>
									
								</c:when>
								<c:when test="${list.type=='材料设备' }">
									<option value="材料设备">材料设备</option>
									<option value="食物">食物</option>
									<option value="生活用品">生活用品</option>
									<option value="机械设备">机械设备</option>
									<option value="其他">其他</option>
								</c:when>
								<c:when test="${list.type=='机械设备' }">
									<option value="机械设备">机械设备</option>
									<option value="食物">食物</option>
									<option value="生活用品">生活用品</option>
									<option value="材料设备">材料设备</option>
									<option value="其他">其他</option>
								</c:when>
								<c:when test="${list.type=='其他' }">
									<option value="其他">其他</option>
									<option value="食物">食物</option>
									<option value="生活用品">生活用品</option>
									<option value="材料设备">材料设备</option>
									<option value="机械设备">机械设备</option>
								</c:when>
								<c:otherwise>
									<option value="食物">食物</option>
									<option value="生活用品">生活用品</option>
									<option value="材料设备">材料设备</option>
									<option value="机械设备">机械设备</option>
									<option value="其他">其他</option>
								</c:otherwise>
							</c:choose>
						</select>
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label" for="dept">所属单位</label>
					<div class="col-md-9">
						<c:choose>
							<c:when test="${bean.power==0 }">
								<input type="text" name="mbean.dept" value="系统管理员"
									disabled="disabled" class="form-control" />
							</c:when>
							<c:when test="${bean.power==1 }">
								<input type="text" name="mbean.dept" value="应急办工作人员"
									disabled="disabled" class="form-control" />
							</c:when>
							<c:when test="${bean.power==2 }">
								<input type="text" name="mbean.dept" value="地震局工作人员"
									disabled="disabled" class="form-control" />
							</c:when>
							<c:when test="${bean.power==3 }">
								<input type="text" name="mbean.dept" value="气象局工作人员"
									disabled="disabled" class="form-control" />
							</c:when>
							<c:when test="${bean.power==4 }">
								<input type="text" name="mbean.dept" value="水文局工作人员"
									disabled="disabled" class="form-control" />
							</c:when>
						</c:choose>
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label" for="num">物资数量</label>
					<div class="col-md-9">
						<input class="form-control" name="mbean.num" type="text"
							value="${list.num }" />
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label" for="unit">计量单位</label>
					<div class="col-md-9">
						<input class="form-control" name="mbean.unit" type="text"
							value="${list.unit }" />
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label" for="name">存放地址</label>
					<div class="col-md-9">
						<input class="form-control" name="mbean.address" type="text"
							value="${list.address }" />
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label" for="name">物资存入时间</label>
					<div class="col-md-9">
						<input class="form-control" name="mbean.storageBeginTime"
							type="text" value="${list.storageBeginTime }" />
					</div>
				</div>
				<div class="form-group">
					<label class="col-md-3 control-label" for="name">物资有效时间</label>
					<div class="col-md-9">
						<input class="form-control" name="mbean.efficiencyTime"
							type="text" value="${list.efficiencyTime }" />
					</div>
				</div>
				<div class="form-group">
					<input name="mbean.id" value="${list.id }" type="hidden" /> <input
						name="userId" value="${list.userBean.id }" type="hidden" />
				</div>
				<div class="form-group">
					<div class="col-md-offset-3 col-md-9">
						<button type="submit" class="btn btn-primary btn-block">
							修改</button>
					</div>
				</div>
			</form>
		</div>
		<div class="col-md-3"></div>
	</div>
	<script
		src="${pageContext.request.contextPath}/static/js/jquery-1.12.1.js"
		type="text/javascript"></script>
	<script
		src="${pageContext.request.contextPath}/static/bootstrap-3.3.5-dist/js/bootstrap.js"
		type="text/javascript"></script>
	<script
		src="${pageContext.request.contextPath}/static/js/jquery.validate.js"
		type="text/javascript"></script>
	<script
		src="${pageContext.request.contextPath}/static/js/myValidate.js"
		type="text/javascript"></script>
</body>
</html>